package com.myperson.controller;

import com.myperson.service.IMassageProvider;
import com.person.common.CommonResult;
import com.sun.xml.internal.ws.api.Component;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 发送消息controller
 *
 * @author zhangfc
 * @date 2021/7/5 14:05
 */
@RestController
@RequestMapping("/controller")
public class SendMessageController {
    @Autowired
    private IMassageProvider iMassageProvider;

    @GetMapping("/sendmsg")
    public CommonResult sendMsg() {
       String msg = iMassageProvider.send();
        return CommonResult.ok(200, "已经发送", msg);
    }
}
